package com.chenfwind.serviceImpl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.chenfwind.IDao.TrajectoryMapper;
import com.chenfwind.domain.Trajectory;
import com.chenfwind.service.TrajectoryService;

@Service("trajectoryService")
public class TrajectoryServiceImpl implements TrajectoryService{
	
	@Autowired
	private TrajectoryMapper trajectoryMapper;
	
	public List<Trajectory> getAllTrajectoryByBook(String bookId){
		return trajectoryMapper.selectByBook(bookId);
	}
	
	public Trajectory getTrajectoryByBook(String bookId){
		return trajectoryMapper.selectByBookIDAndRank(bookId);
	}
}
